
class matchrow:
    def __init__(self,row,allnum=False):
        if allnum:
            self.data=[float(row[i]) for i in range(len(row)-1)]
        else:
            self.data=row[0:len(row)-1]
            self.match=int(row[len(row)-1])
        
def loadmatch(f,allnum=False):
    rows=[]
    for line in file(f):
        rows.append(matchrow(line.split(','),allnum))
    return rows


agesonly=loadmatch('agesonly.csv',allnum=True)
matchmaker=loadmatch('matchmaker.csv')
